import { setToken, getToken, removeToken } from "@/utils/accessToken";

const state = {
  token: getToken(),
};
const getter = {};
const mutations = {
  setToken(state, val) {
    state.token = val;
    setToken(val);
  },
  removeToken(state, val) {
    state.token = "";
    removeToken();
  },
};
const actions = {};
export default {
  state,
  getter,
  mutations,
  actions,
};
